package com.fqgj.sentry.manage;


import com.fqgj.sentry.manage.dao.McRolePermissionDao;
import com.fqgj.sentry.manage.entity.McRolePermissionEntity;
import com.fqgj.sentry.manage.service.RolePermissionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * Created by lpp
 *
 * @description
 * @create 2017-07-13 下午5:38
 */

@Service
public class RolePermissionServiceImpl implements RolePermissionService {

    @Autowired
    private McRolePermissionDao rolePermissionDao;

    @Override
    public McRolePermissionEntity insert(McRolePermissionEntity rolePermissionEntity) {
        return rolePermissionDao.insert(rolePermissionEntity);
    }

    @Override
    public Integer deleteByRoleId(Long roleId) {
        return rolePermissionDao.deleteByRoleId(roleId);
    }

    @Override
    public List<McRolePermissionEntity> findListByRoleId(Long roleId) {
        return rolePermissionDao.findListByRoleId(roleId);
    }

    @Override
    public List<McRolePermissionEntity> selectListByRolesId(String rolesId) {
        return rolePermissionDao.selectListByRolesId(rolesId);
    }
}
